//
//  ILMusicListModel.m
//  ILife
//
//  Created by lanou on 15/10/26.
//  Copyright © 2015年 ILife. All rights reserved.
//

#import "ILMusicListModel.h"

@implementation ILMusicListModel

-(ILCategoryModel *)category
{
    if (_category == nil) {
        self.category = [[ILCategoryModel alloc]init];
    }
    return _category;
}

-(ILArticleDataModel *)articleData
{

    if (_articleData == nil) {
        self.articleData = [[ILArticleDataModel alloc]init];
    }
    return _articleData;
}

-(ILMusicResourceModel *)resource
{
    if (_resource == nil) {
        self.resource = [[ILMusicResourceModel alloc]init];
    }
    return _resource;
}

-(void)setValue:(id)value forKey:(NSString *)key
{
    if ([key isEqualToString:@"id"]) {
        _musicId = value;
    }else if([key isEqualToString:@"articleData"])
    {
        [self.articleData setValuesForKeysWithDictionary:value];
    }else if([key isEqualToString:@"category"])
    {
        [self.category setValuesForKeysWithDictionary:value];
    }else if([key isEqualToString:@"description"])
    {
        _MusicDescription = value;
    }else if([key isEqualToString:@"resource"])
    {
        [self.resource setValuesForKeysWithDictionary:value];
    }else
    {
        [super setValue:value forKey:key];
    }
}


@end
